﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Sunboxsoft.ASMS.Client.Domain.WebRef
{
    public partial class ESettlementBillMaterial
    {
        /// <summary>
        /// 商品名称
        /// </summary>
        public string MaterialName { get; set; }

        /// <summary>
        /// 商品状态
        /// </summary>
        public int MaterialStatus { get; set; }


        /// <summary>
        /// 总金额
        /// </summary>
        public decimal ActualAmount
        {
            get
            {
                return Math.Round(this.Price * this.Count * this.Discount, 2);
            }
        }

        /// <summary>
        /// 状态(文字)
        /// </summary>
        public string MaterialStatusText
        {
            get
            {
                return Constant.MaintenanceBillMaterialStatus.GetText(this.MaterialStatus);
            }
        }

        public ESettlementBillMaterial()
        {
        }

        public ESettlementBillMaterial(Guid maintenanceBillMaterialId,string materialName, int materialStatus)
        {
            MaintenanceBillMaterialId = maintenanceBillMaterialId;
            MaterialName = materialName;
            MaterialStatus = materialStatus;
        }
    }
}
